package hibernate;

import org.hibernate.cfg.AnnotationConfiguration;
import org.hibernate.tool.hbm2ddl.SchemaExport;

import br.upis.pf1.entity.Cliente;
import br.upis.pf1.entity.Evento;
import br.upis.pf1.entity.Login;
import br.upis.pf1.entity.Pagamento;
import br.upis.pf1.entity.Plano;

public class GerarTabelas {
	public static void main(String[] args) {
		AnnotationConfiguration cfg = new AnnotationConfiguration().configure();
		cfg.addAnnotatedClass(Cliente.class);
		cfg.addAnnotatedClass(Login.class);
		cfg.addAnnotatedClass(Evento.class);
		cfg.addAnnotatedClass(Plano.class);
		cfg.addAnnotatedClass(Pagamento.class);

		SchemaExport se = new SchemaExport(cfg);
		se.create(true, true);
		System.out.println("Tabelas geradas...");
	}
}